			<div id="top">
			<div class="nr">
				<div class="left">
					{{if value="(isset($_SESSION['username']))"}}
					<span class="welcome">您好,<a href="{{U('Myheart/index')}}">{{$_SESSION['username']}}</a>!</span>
					<span class="login"style="width:140px;margin-left:-30px;">
						<a href="{{U('Login/out')}}">退出登录</a>|<a href="{{U('Login/index')}}">更换用户</a>
					</span>
					{{else}}
					<span class="welcome">您好,欢迎光临凡客诚品!</span>
					<span class="login">
						<a href="{{U('Login/index')}}">登陆</a>|<a href="{{U('Register/index')}}">注册</a>
					</span>
					{{endif}}
					<li><a href="">我的订单</a></li> 
					<li><a href="">收藏本站</a></li>
					<li><a href="" class='red'>双十一退换货说明</a></li>

				</div>
				<div class="right">
					<li class='fanke'><a href="">我的凡客<span class='erji'>我的订单</span></a><span class='ico'>
						
					</span></li>
					<li><a href="">网站导航</a><span class='ico'></span></li>
					<li><a href="">网站导航</a><span class='ico'></span></li>
					<li><a href="">帮助中心</a><span class='ico'></span></li>
					<li><a href="">网站公告</a><span class='ico'></span></li>
					<li><a href="">手机凡客</a><span class='mobel'></span></li>
					<li><a href="">在线客服</a><span class='kefu'></span></li>
					<span class="weixin"></span>
					<span class="weibo"></span>

				</div>
			</div>
		</div>
		<div id="search">
			<div class="search">
				<div class="left">
					
				</div>
				<div class="mid">
					<form action='' method="post">
						<input type="text" name="hh" value="男士羽绒服" class='text' />
						<input type="submit" value="搜索"class='btn' />
					</form>
					<p>
						<span>热门搜索：</span>
						<a href="">衬衫</a>
					<a href="">羽绒服</a>
					<a href="">针织衫</a>
					<a href="">羊毛外套</a>
					<a href="">休闲裤</a>
					<a href="">牛仔裤</a>
					</p>
				</div>
				<div class="cart">
					<div class="top">
						<span>购物车</span>
						
					</div>
					{{if value="isset($_SESSION['cart'])"}}{
						<p><a href="{{U('Buycar/index')}}"style="color:red;line-height:25px;">你的购物车有<span style="font-size: 20px;margin:0 10px;color:#000000;">{{$_SESSION['cart']['total_rows']}}</span>件产品</a></p>
					{{else}}
						<p>你的购物车没有任何产品</p>
					{{endif}}
					
						
					
				</div>
			</div>
		</div>
		<?php  //		载入分类
		$category=new \Common\Model\Category;
		//获得所有分类
		$catedata=$category->where('pid',0)->get();
		
		foreach($catedata as $k=>$v){
			$catedata[$k]['son']=$category->where('pid',$v['cid'])->get();
			foreach($catedata[$k]['son'] as $sk=>$sv){
			$catedata[$k]['son'][$sk]['nextson']=$category->where('pid',$sv['cid'])->get();
			}
		} ?>
			<!--导航条-->
		<div id="nav">
			<div class="nav">
				<div class="left">
					全部商品分类
				</div>
				<div class="right">
					
					<ul>
						{{foreach from="$catedata" value="$v"}}
						
						<li>
							<a href="{{U('List/index',array('cid'=>$v['cid']))}}">{{$v['cname']}}</a>
							<div class="tab">
								<div class="tableft">
									<div class="le">
										<a href="" class="img"><img src="{{__PUBLIC__}}/Home/images/6367352-1j.jpg" alt="" /></a>
									</div>
									
									<div class="re">
										<a href="" class="kuan">男款</a>
										<span class="word">超轻羽绒服 鹅绒造 更保暖 无异味</span>
										<span class="price">￥399</span>
									</div>
									
								</div>
								
								<div class="tableft" style="border:none;">
									<div class="le">
										<a href="" class="img"><img src="{{__PUBLIC__}}/Home/images/6367352-1j.jpg" alt="" /></a>
									</div>
									
									<div class="re">
										<a href="" class="kuan">nv款</a>
										<span class="word">超轻羽绒服 鹅绒造 更保暖 无异味</span>
										<span class="price">￥399</span>
									</div>
									
								</div>
							</div>
						</li>

							{{endforeach}}	
						
					</ul>
				
				</div>
			
			</div>
		</div>
	